#include<ros/ros.h>
#include<std_msgs/Float32.h>

void callback_a(const std_msgs::Float32& cmd_a)
{
    std_msgs::Float32 b;
    b.data=cmd_a.data*2.0;
    ROS_INFO("b=%f", b.data);
}

int main(int argc, char** argv)
{
    ros::init(argc,argv,"q3_1b");
    ros::NodeHandle n;
    ros::Subscriber sub_a=n.subscribe("send_a",1000,callback_a);
    ros::spin();
    return 1;
}